package com.morningstar.qs.basic.db.bean;

import java.io.Serializable;

import com.morningstar.qs.basic.db.util.BeanBase;

/**
 * This is an object that contains data related to the InternalUserGroupMapping
 * table. Do not modify this class because it will be overwritten if the
 * configuration file related to this class is modified.
 *
 * @hibernate.class table="InternalUserGroupMapping"
 */

public class InternalUserGroupMapping extends BeanBase implements Serializable {

	/*
	 * public static String REF = "InternalUserGroupMapping"; public static
	 * String PROP_CREATE_TIME = "createTime"; public static
	 * String PROP_LAST_UPDATE_TIME = "lastUpdateTime"; public static String PROP_ID =
	 * "id";
	 */

	public byte getValid() {
		return valid;
	}

	public void setValid(byte valid) {
		this.valid = valid;
	}


	/**
	 *
	 */
	private static final long serialVersionUID = -4376560725286741407L;

	// constructors
	public InternalUserGroupMapping() {
	}

	public InternalUserGroupMapping(int userId, short groupId) {
		this.userId=userId;
		this.groupId=groupId;
	}


	private int hashCode = Integer.MIN_VALUE;

	// composite primary key
	private int userId;
	private short groupId;

	// fields
	private java.util.Date createTime;
	private java.util.Date lastUpdateTime;
	private short isDefault;
	private byte valid;

	/**
	 * Return the value associated with the column: CreateTime
	 */
	public java.util.Date getCreateTime() {
		return createTime;
	}

	/**
	 * Set the value related to the column: CreateTime
	 *
	 * @param createTime
	 *            the CreateTime value
	 */
	public void setCreateTime(java.util.Date createTime) {
		this.createTime = createTime;
	}

	/**
	 * Return the value associated with the column: LastUpdateTime
	 */
	public java.util.Date getLastUpdateTime() {
		return lastUpdateTime;
	}

	/**
	 * Set the value related to the column: LastUpdateTime
	 *
	 * @param lastUpdateTime
	 *            the LastUpdateTime value
	 */
	public void setLastUpdateTime(java.util.Date lastUpdateTime) {
		this.lastUpdateTime = lastUpdateTime;
	}

	public int getUserId() {
		return userId;
	}

	public void setUserId(int userId) {
		this.userId = userId;
	}

	public short getGroupId() {
		return groupId;
	}

	public void setGroupId(short groupId) {
		this.groupId = groupId;
	}

	public short getIsDefault() {
		return isDefault;
	}

	public void setIsDefault(short isDefault) {
		this.isDefault = isDefault;
	}

	@Override
	public String toString() {
		return "InternalUserGroupMapping [createTime=" + this.createTime
				+ ", groupId=" + this.groupId + ", hashCode=" + this.hashCode
				+ ", lastUpdateTime=" + this.lastUpdateTime + ", userId="
				+ this.userId + "]";
	}
}